import Ember from 'ember';
import RSVP from 'rsvp';
import config from 'mall-app-front/config/environment';

export default Ember.Route.extend({
  model() {
    return RSVP.hash({
      slides: Ember.$.getJSON(config.rootURL + "api/slides", {target:"HOME_BANNER"}),
      categories:Ember.$.getJSON(config.rootURL + "api/productCategories"),
      categoryProducts:[
        {
          "id": "1",
          "name": "潮流",
          "parentId": "",
          "thumb": "",
          "description": "潮流一级",
          "sortOrder": 0,
          "adUri": "",
          "adImage": "",
          "enabled": false,
          "home": false,
          "level": 1,
          "children": [],
          "products":[
            {
              "id": "12",
              "title": "[原创]STEP 背心",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/07/W0ivN633VuIvGLPlpL6bfOvVN8zH5h.jpg",
              "marketprice": "2000.00",
              "productprice": "1.00",
              "sales": "43",
              "total": "367",
              "description": ""
            },
            {
              "id": "9",
              "title": "[原创]STEP 弯檐帽【手势】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/FAkQQflplgffbpU33x83mFAL8qIbBZ.jpeg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "143",
              "total": "75",
              "description": ""
            },
            {
              "id": "22",
              "title": "字母短袖针织衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/wZ5iYXduHDO5sHX2msVd2um2vDvddI.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "163",
              "total": "10000",
              "description": ""
            },
            {
              "id": "54",
              "title": "波哥牌内衣【安全有保障】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/oMUPsWzyLy92Ii2eHNIY9sIGE2Z2k2.jpg",
              "marketprice": "9998.00",
              "productprice": "100088.00",
              "sales": "1125",
              "total": "9986",
              "description": ""
            },
            {
              "id": "53",
              "title": "成都欢乐谷日场通票",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/RdNRQGUJ54gPQun8k7DGkOK7RzOGWw.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "0",
              "total": "10000",
              "description": ""
            },
            {
              "id": "52",
              "title": "【工业密码】男款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/Hp77Z12gq610VTz125p8aI30vma577.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9997",
              "description": ""
            },
            {
              "id": "51",
              "title": "【线条主义】卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/L5Dx5siIL4sD9TpEL5Wl7ezWZt9lit.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "1",
              "total": "9999",
              "description": ""
            },
            {
              "id": "50",
              "title": "【都市情结】女款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/rAiJ1ue5WDMWs5QTp5sIj8q4pwUS5E.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9999",
              "description": ""
            },
            {
              "id": "46",
              "title": "撞色针织套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/Bb5Ea2E0Bovu07qSAoCmuo5mAV1Ex5.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            },
            {
              "id": "45",
              "title": "针织假两件套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/NoaYa44K3L3lOFaA44MvySlfOaf00S.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            }]
        },
        {
          "id": "11",
          "name": "庞克",
          "parentId": "1",
          "thumb": "",
          "description": "潮流下的二级",
          "sortOrder": 11,
          "adUri": "aaaaaa",
          "adImage": "",
          "enabled": false,
          "home": false,
          "level": 2,
          "children": [],
          "products":[
            {
              "id": "12",
              "title": "[原创]STEP 背心",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/07/W0ivN633VuIvGLPlpL6bfOvVN8zH5h.jpg",
              "marketprice": "2000.00",
              "productprice": "1.00",
              "sales": "43",
              "total": "367",
              "description": ""
            },
            {
              "id": "9",
              "title": "[原创]STEP 弯檐帽【手势】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/FAkQQflplgffbpU33x83mFAL8qIbBZ.jpeg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "143",
              "total": "75",
              "description": ""
            },
            {
              "id": "22",
              "title": "字母短袖针织衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/wZ5iYXduHDO5sHX2msVd2um2vDvddI.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "163",
              "total": "10000",
              "description": ""
            },
            {
              "id": "54",
              "title": "波哥牌内衣【安全有保障】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/oMUPsWzyLy92Ii2eHNIY9sIGE2Z2k2.jpg",
              "marketprice": "9998.00",
              "productprice": "100088.00",
              "sales": "1125",
              "total": "9986",
              "description": ""
            },
            {
              "id": "53",
              "title": "成都欢乐谷日场通票",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/RdNRQGUJ54gPQun8k7DGkOK7RzOGWw.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "0",
              "total": "10000",
              "description": ""
            },
            {
              "id": "52",
              "title": "【工业密码】男款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/Hp77Z12gq610VTz125p8aI30vma577.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9997",
              "description": ""
            },
            {
              "id": "51",
              "title": "【线条主义】卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/L5Dx5siIL4sD9TpEL5Wl7ezWZt9lit.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "1",
              "total": "9999",
              "description": ""
            },
            {
              "id": "50",
              "title": "【都市情结】女款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/rAiJ1ue5WDMWs5QTp5sIj8q4pwUS5E.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9999",
              "description": ""
            },
            {
              "id": "46",
              "title": "撞色针织套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/Bb5Ea2E0Bovu07qSAoCmuo5mAV1Ex5.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            },
            {
              "id": "45",
              "title": "针织假两件套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/NoaYa44K3L3lOFaA44MvySlfOaf00S.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            }]
        },
        {
          "id": "380a73d7a5032e8f656c11736be80455",
          "name": "2",
          "parentId": "",
          "thumb": "http://www.localhost:8080/file/images/2016/10/a4c1e43c93605c4835c6ccac02101b1d.jpg",
          "description": "2",
          "sortOrder": 2,
          "adUri": "3",
          "adImage": "http://www.localhost:8080/file/images/2016/10/61fa001d8401adfeda57e6e133fc9c36.jpg",
          "enabled": false,
          "home": false,
          "level": 1,
          "children": [],
          "products":[
            {
              "id": "12",
              "title": "[原创]STEP 背心",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/07/W0ivN633VuIvGLPlpL6bfOvVN8zH5h.jpg",
              "marketprice": "2000.00",
              "productprice": "1.00",
              "sales": "43",
              "total": "367",
              "description": ""
            },
            {
              "id": "9",
              "title": "[原创]STEP 弯檐帽【手势】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/FAkQQflplgffbpU33x83mFAL8qIbBZ.jpeg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "143",
              "total": "75",
              "description": ""
            },
            {
              "id": "22",
              "title": "字母短袖针织衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/wZ5iYXduHDO5sHX2msVd2um2vDvddI.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "163",
              "total": "10000",
              "description": ""
            },
            {
              "id": "54",
              "title": "波哥牌内衣【安全有保障】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/oMUPsWzyLy92Ii2eHNIY9sIGE2Z2k2.jpg",
              "marketprice": "9998.00",
              "productprice": "100088.00",
              "sales": "1125",
              "total": "9986",
              "description": ""
            },
            {
              "id": "53",
              "title": "成都欢乐谷日场通票",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/RdNRQGUJ54gPQun8k7DGkOK7RzOGWw.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "0",
              "total": "10000",
              "description": ""
            },
            {
              "id": "52",
              "title": "【工业密码】男款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/Hp77Z12gq610VTz125p8aI30vma577.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9997",
              "description": ""
            },
            {
              "id": "51",
              "title": "【线条主义】卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/L5Dx5siIL4sD9TpEL5Wl7ezWZt9lit.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "1",
              "total": "9999",
              "description": ""
            },
            {
              "id": "50",
              "title": "【都市情结】女款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/rAiJ1ue5WDMWs5QTp5sIj8q4pwUS5E.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9999",
              "description": ""
            },
            {
              "id": "46",
              "title": "撞色针织套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/Bb5Ea2E0Bovu07qSAoCmuo5mAV1Ex5.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            },
            {
              "id": "45",
              "title": "针织假两件套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/NoaYa44K3L3lOFaA44MvySlfOaf00S.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            }]
        },
        {
          "id": "16b0f65f83b6983d5668c626d844bce6",
          "name": "21",
          "parentId": "380a73d7a5032e8f656c11736be80455",
          "thumb": "http://www.localhost:8080/file/images/2016/10/b1b9b957ac9d39d118fd7d8440c431fb.jpg",
          "description": "22221111",
          "sortOrder": 21,
          "adUri": "21",
          "adImage": "",
          "enabled": true,
          "home": false,
          "level": 2,
          "children": [],
          "products":[
            {
              "id": "12",
              "title": "[原创]STEP 背心",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/07/W0ivN633VuIvGLPlpL6bfOvVN8zH5h.jpg",
              "marketprice": "2000.00",
              "productprice": "1.00",
              "sales": "43",
              "total": "367",
              "description": ""
            },
            {
              "id": "9",
              "title": "[原创]STEP 弯檐帽【手势】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/FAkQQflplgffbpU33x83mFAL8qIbBZ.jpeg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "143",
              "total": "75",
              "description": ""
            },
            {
              "id": "22",
              "title": "字母短袖针织衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/wZ5iYXduHDO5sHX2msVd2um2vDvddI.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "163",
              "total": "10000",
              "description": ""
            },
            {
              "id": "54",
              "title": "波哥牌内衣【安全有保障】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/oMUPsWzyLy92Ii2eHNIY9sIGE2Z2k2.jpg",
              "marketprice": "9998.00",
              "productprice": "100088.00",
              "sales": "1125",
              "total": "9986",
              "description": ""
            },
            {
              "id": "53",
              "title": "成都欢乐谷日场通票",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/RdNRQGUJ54gPQun8k7DGkOK7RzOGWw.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "0",
              "total": "10000",
              "description": ""
            },
            {
              "id": "52",
              "title": "【工业密码】男款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/Hp77Z12gq610VTz125p8aI30vma577.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9997",
              "description": ""
            },
            {
              "id": "51",
              "title": "【线条主义】卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/L5Dx5siIL4sD9TpEL5Wl7ezWZt9lit.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "1",
              "total": "9999",
              "description": ""
            },
            {
              "id": "50",
              "title": "【都市情结】女款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/rAiJ1ue5WDMWs5QTp5sIj8q4pwUS5E.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9999",
              "description": ""
            },
            {
              "id": "46",
              "title": "撞色针织套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/Bb5Ea2E0Bovu07qSAoCmuo5mAV1Ex5.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            },
            {
              "id": "45",
              "title": "针织假两件套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/NoaYa44K3L3lOFaA44MvySlfOaf00S.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            }]
        },
        {
          "id": "b35ea5d7bb8d479abef4521b7409c994",
          "name": "22",
          "parentId": "380a73d7a5032e8f656c11736be80455",
          "thumb": "",
          "description": "",
          "sortOrder": 22,
          "adUri": "",
          "adImage": "",
          "enabled": true,
          "home": true,
          "level": 2,
          "children": [],
          "products":[
            {
              "id": "12",
              "title": "[原创]STEP 背心",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/07/W0ivN633VuIvGLPlpL6bfOvVN8zH5h.jpg",
              "marketprice": "2000.00",
              "productprice": "1.00",
              "sales": "43",
              "total": "367",
              "description": ""
            },
            {
              "id": "9",
              "title": "[原创]STEP 弯檐帽【手势】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/FAkQQflplgffbpU33x83mFAL8qIbBZ.jpeg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "143",
              "total": "75",
              "description": ""
            },
            {
              "id": "22",
              "title": "字母短袖针织衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/wZ5iYXduHDO5sHX2msVd2um2vDvddI.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "163",
              "total": "10000",
              "description": ""
            },
            {
              "id": "54",
              "title": "波哥牌内衣【安全有保障】",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/oMUPsWzyLy92Ii2eHNIY9sIGE2Z2k2.jpg",
              "marketprice": "9998.00",
              "productprice": "100088.00",
              "sales": "1125",
              "total": "9986",
              "description": ""
            },
            {
              "id": "53",
              "title": "成都欢乐谷日场通票",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/RdNRQGUJ54gPQun8k7DGkOK7RzOGWw.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "0",
              "total": "10000",
              "description": ""
            },
            {
              "id": "52",
              "title": "【工业密码】男款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/Hp77Z12gq610VTz125p8aI30vma577.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9997",
              "description": ""
            },
            {
              "id": "51",
              "title": "【线条主义】卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/L5Dx5siIL4sD9TpEL5Wl7ezWZt9lit.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "1",
              "total": "9999",
              "description": ""
            },
            {
              "id": "50",
              "title": "【都市情结】女款卫衣",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/09/rAiJ1ue5WDMWs5QTp5sIj8q4pwUS5E.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "24",
              "total": "9999",
              "description": ""
            },
            {
              "id": "46",
              "title": "撞色针织套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/Bb5Ea2E0Bovu07qSAoCmuo5mAV1Ex5.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            },
            {
              "id": "45",
              "title": "针织假两件套头衫",
              "thumb": "http://chongzhi.inkanke.com/attachment/images/3/2016/08/NoaYa44K3L3lOFaA44MvySlfOaf00S.jpg",
              "marketprice": "1.00",
              "productprice": "1.00",
              "sales": "189",
              "total": "10000",
              "description": ""
            }]
        }
      ]
    });
  }
});
